package spring.IoCDemo;

import org.junit.Test;

public class Parent {

    OrangeSeller orangeSeller = new OrangeSeller();
    @Test
    public void execute() {
        Son son = new Son();
        son.setSeller(orangeSeller); //你站在原地别动
        System.out.println("你站在原地别动");
        son.buyOrange(); //我去帮你买水果
    }
}
